package com.leo.train.business.controller.admin;

import com.leo.train.business.dto.ConfirmOrderDto;
import com.leo.train.business.entity.ConfirmOrder;
import com.leo.train.business.service.ConfirmOrderService;
import com.leo.train.common.resp.CommonResp;
import com.leo.train.common.resp.PageResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/admin/confirmOrder")
public class ConfirmOrderAdminController {
    @Autowired
    private ConfirmOrderService confirmOrderService;
    /**
     * 查询确认订单列表
     * @param confirmOrderDto
     * @return
     */
    @GetMapping("/list")
    public CommonResp<PageResult<ConfirmOrder>> list(ConfirmOrderDto confirmOrderDto) {
        PageResult<ConfirmOrder> pageResult = confirmOrderService.list(confirmOrderDto);
        return new CommonResp<>(pageResult);
    }

}
